package com.example.yeujian5.yuejian5.service;

import com.example.yeujian5.yuejian5.bean.TrainBean;

import java.util.List;

import retrofit2.Call;
import retrofit2.http.GET;
import retrofit2.http.Path;
import retrofit2.http.Query;

/**
 * Created by wangmengmeng on 2017/10/9.
 */

public interface TrainService {

    //全部列表
    @GET("lists/mod/train")
    Call<List<TrainBean>> getTrainList(
    );

    //分级列表
    @GET("lists/mod/{mod}/SessionID/{SessionID}/degree/{degree}")
    Call<List<TrainBean>> getTrainClass(
            @Path("SessionID") String SessionID,
            @Path("mod") String mod,
            @Path("degree") String degree
    );


    //详情
    @GET("get/mod/train")
    Call<TrainBean> getTrainById(
            @Query("SessionID")   String sessionId,
            @Query("id") String id
    );





    //训练报名
    @GET("create/mod/{mod}/participantname/{participantname}/train_id/{train_id}/participanttel/{participanttel}/adultnum/{adultnum}/" +
            "paytype/{paytype}/pay/{pay}/paynotice/{paynotice}/userid/{userid}/SessionID/{SessionID}")
    Call<Integer> signTrain(
            @Path("mod") String mod,
            @Path("participantname") String participantname,
            @Path("train_id") String train_id,
            @Path("participanttel") String participanttel,
            @Path("adultnum") String adultnum,
            @Path("paytype") String paytype,
            @Path("pay") String pay,
            @Path("paynotice") String paynotice,
            @Path("userid") int userid,
            @Path("SessionID") String SessionID
    );
}
